{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "7d941e75-5b09-4cb6-9b0f-6fbdc5e08388",
   "metadata": {},
   "source": [
    "# Simple Box Plot\n",
    "\n",
    "A simple box and whisker plot for visualizing the distribution and spread of numeric values grouped by category.\n",
    "This example shows how to create a box plot using a small dataset with categories."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "44583f96-98d7-47db-afa7-f19df86a8d66",
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd\n",
    "import numpy as np\n",
    "import hvplot.pandas  # noqa\n",
    "\n",
    "np.random.seed(0)\n",
    "df = pd.DataFrame({\n",
    "    'group': np.random.choice(['A', 'B', 'C'], size=100),\n",
    "    'score': np.random.normal(loc=75, scale=10, size=100)\n",
    "})\n",
    "\n",
    "df.hvplot.box(y='score', by='group', title='Simple Box Plot (Bokeh)')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "6825dcde-303a-4ee0-88bb-fc7a630fa37e",
   "metadata": {},
   "outputs": [],
   "source": [
    "import pandas as pd\n",
    "import numpy as np\n",
    "import hvplot.pandas  # noqa\n",
    "hvplot.extension('matplotlib')\n",
    "\n",
    "np.random.seed(0)\n",
    "df = pd.DataFrame({\n",
    "    'group': np.random.choice(['A', 'B', 'C'], size=100),\n",
    "    'score': np.random.normal(loc=75, scale=10, size=100)\n",
    "})\n",
    "\n",
    "df.hvplot.box(y='score', by='group', title='Simple Box Plot (Matplotlib)')"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "4635a37b-774e-4789-9be6-6dc62f5a4672",
   "metadata": {},
   "source": [
    ":::{seealso}\n",
    "- [Box Plots reference documentation](../../ref/api/manual/hvplot.hvPlot.box.ipynb).\n",
    ":::"
   ]
  }
 ],
 "metadata": {
  "language_info": {
   "name": "python",
   "pygments_lexer": "ipython3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
